package org.amos.api.upms.dto;


import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.Data;
import org.amos.core.basic.annotation.MpQuery;
import org.amos.core.basic.base.BaseDTO;
import org.amos.core.basic.enums.SqlKeyWordEnum;


/**
 * 字典详情DTO
 *
 * @author CodeGenerator
 * @since 2020-12-20
 */
@Data
public class DictDetailDTO extends BaseDTO {

    @MpQuery(column = "dict_id", keyword = SqlKeyWordEnum.EQ)
    private Long dictId;

    @NotBlank(message = "字典code不能为空")
    @Schema(description = "字典code")
    @MpQuery(column = "dict_code", keyword = SqlKeyWordEnum.EQ)
    private String dictCode;

    @NotBlank(message = "字典名称不能为空")
    @MpQuery(column = "name", keyword = SqlKeyWordEnum.LIKE)
    @Schema(description = "字典名称")
    private String name;

    @NotNull(message = "字典值不能为空")
    @Schema(description = "字典值")
    private Integer value;

    @Schema(description = "备注")
    private String remark;

    @Schema(description = "状态 1:有效 ,0:无效")
    @NotNull(message = "字典状态不能为空")
    private Integer status;

    @MpQuery(column = "sort", keyword = SqlKeyWordEnum.ASC)
    @Schema(description = "排序")
    private Integer sort;

}
